package com.ttscm.srds.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * @version:
 * @author:
 * @className:
 * @packageName:
 * @description: 设备配置
 * @date: 2022/07/20
 */
@Component
@ConfigurationProperties(prefix = "device")
@PropertySource(value = "classpath:configs/device.properties")
public final class DeviceParam {
    private String host;
    private int port;
    private int slaveId;

    private String address;

    @Override
    public String toString() {
        return "DeviceParam{" + "host='" + host + '\'' + ", port=" + port + ", slaveId=" + slaveId + ", address='" + address + '\'' + '}';
    }

    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }

    public int getSlaveId() {
        return slaveId;
    }

    public void setSlaveId(int slaveId) {
        this.slaveId = slaveId;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }
}
